const mongoose = require('mongoose');

require("./studentsModel");
require("./exercisesModel");

const errorsSchema = new mongoose.Schema({
    studentId: {   // 所属学员 _id
        type: mongoose.Schema.Types.ObjectId,
        ref: 'studentsModel'
    },
    exerciseId: {
        type: mongoose.Schema.Types.ObjectId,
        ref: 'exercisesModel'
    },
    errorAnswer: Number, // 错误答案
});
mongoose.model('errorsModel', errorsSchema, 'errors');